#!/bin/bash
while true
do
skip=`head -$1 $2 | grep skip | awk -F= '{print $2}'`
tail -n +$skip $2 > $2.gz
gunzip -f $2.gz || exit
done
